package com.hefeng.example.service;


import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.IService;
import com.hefeng.example.domain.CustomerManualWorkOrder;
import com.hefeng.example.domain.DeviceAutomaticAlarmWorkOrder;
import com.hefeng.example.domain.WorkOrderDispositionResult;
import org.apache.ibatis.annotations.Param;

import java.util.List;
import java.util.Map;

public interface CustomerManualWorkOrderService extends IService<CustomerManualWorkOrder> {

    /**
     * 根据工单id获取设备信息
     *
     * @param id
     * @return
     */
    List<Map> WorkDeviceInfo(Integer id);


    Page<CustomerManualWorkOrder> getDeviceList(CustomerManualWorkOrder customerManualWorkOrder, long current, long size);


    /**
     * 获取工单详情
     *
     * @param id
     * @return
     */
    List<Map> WorkOrderDetails(@Param(value = "id") String id);


    /**
     * 获取转单工单详情
     */
    List<Map> turnWork(@Param(value = "id") String id);


    /**
     * 已完成工单详情
     */
    List<Map> finishWork(@Param(value = "id") String id);

    /**
     * 生成转派工单
     *
     * @return
     */

    int insert(CustomerManualWorkOrder customerManualWorkOrder);

    /**
     * 创建已转派结果表
     */
    int insertT(WorkOrderDispositionResult workOrderDispositionResult);

    void updateWorkAndDispatchStatus(String workId, String workType, Integer workStatus, Integer dispatchStatus, String workOverdue, String deviceAlarmId);

    /**
     * 更新用户手动工单
     *
     * @param
     */
    void updateCustomerManualWorkOrder(CustomerManualWorkOrder customerManualWorkOrder);

    void createWorkHandleResult(WorkOrderDispositionResult workOrderDispositionResult);


}
